Previous Book Contents Book Index Next

Inside Macintosh: QuickDraw GX Objects /
Chapter 1 - Introduction to QuickDraw GX / Objects and Memory


External Storage of Objects: Flattening and Unflattening

QuickDraw GX objects exist (as objects) only in memory. You must convert
a QuickDraw GX shape (a shape object and its referenced objects) into an equivalent compressed description in order to save it to external storage, transmit it across a network, or store it in the Clipboard. This process of converting objects to a compressed format that is no longer object-based is called flattening. The flattened information is a stream-based description with a public format, so that applications can share the data and reconstruct the objects from which the flattened stream was generated.

The data of flattened objects follows the format defined in the stream format chapter
of Inside Macintosh: QuickDraw GX Environment and Utilities. To reconstruct a shape's object-based description from its flattened stream, you can manually create and initialize a set of objects based on the information in the stream, or--if QuickDraw GX is available--you can use QuickDraw GX functions to do it automatically.

Printing objects are also flattened and unflattened as the documents they are associated with are closed and reopened. For more information, see the core printing features chapter of Inside Macintosh: QuickDraw GX Printing.

Portable digital documents (PDDs) are specialized versions of print files, which are the flattened versions of documents sent to printers. For more information, see "Printing With QuickDraw GX" beginning on page 1-34, and the advanced printing features chapter of Inside Macintosh: QuickDraw GX Printing.

Fonts are represented in QuickDraw GX as font objects, which are flattened for transmission to printers or for external storage. A flattened font's format, however, is not related to the QuickDraw GX stream format. For more information, see the fonts chapter of Inside Macintosh: QuickDraw GX Typography.


Previous Book Contents Book Index Next

© Apple Computer, Inc.
7 JUL 1996